package orign

import "github.com/gin-gonic/gin"
import "net/http"

//setupRouter 方便测试
func setupRouter() *gin.Engine {
	r := gin.Default()
	r.GET("/test", func(context *gin.Context) {
		context.String(200, "pong")
	})
	r.GET("/ping", func(context *gin.Context) {
		context.JSON(http.StatusOK, gin.H{
			"message": "pong",
		})
	})
	return r
}
//func main() {
//	r := setupRouter()
//	r.Run("localhost:9999")
//}
